package com.gw.provider.config;

import org.apache.activemq.command.ActiveMQQueue;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import javax.jms.Queue;

@Configuration //配置类,项目启动里面的配置就会生效
public class ConfigBean { //把消息队列添加到bean容器，交给spring进行管理
    @Bean //<bean id="" class=""></bean>
    public Queue queue(){
        return new ActiveMQQueue("ActiveMQQueue");
    }
}
